package com.slw.caiji.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.slw.caiji.dto.SysMenu;
import com.slw.caiji.dto.SysRole;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Select;

import java.util.List;

@Mapper
public interface SysMenuMapper extends BaseMapper<SysMenu> {
    @Select("select * from sys_menu")
    IPage<SysMenu> listSysMenu(Page<SysMenu> page);

    @Select("select * from sys_menu where name = #{name}")
    List<SysMenu> getParentList(@Param("name") String name);

}
